<?php

namespace app\admin\validate;

use think\Validate;

class BlogValidate extends Validate
{
    protected $rule = [
        'name'=>'require|min:2',
        'neirong'=>'require|min:16',
        'author'=>'require',
        'image'=>'require'
    ];

    protected $message = [
        'name.require'=>'写个标题吧',
        'name.min'=>'您这标题也太短了',
        'neirong.require'=>'不写内容谁能看的懂啊',
        'neirong.min'=>'内容不能少于16个字',
        'author.require'=>'总不能无名无姓吧',
        'image.require'=>'没有图片也太不美观了'
    ];
}
